<?php
$this->breadcrumbs = array(
	'入库单' => array(
		'index'
	),
	'管理',
);

$this->userActions = array(
	array(
		'label' => '入库单列表',
		'url' => array(
			'index'
		),
		'iconClass' => 'icon-lorry'
	),
	array(
		'label' => '新建入库单',
		'url' => array(
			'create'
		),
		'iconClass' => 'icon-lorry-add'
	),
);
?>

<h1>管理入库单</h1>

<?php $this
	->widget('zii.widgets.grid.CGridView',
		array(
			'id' => 'material-warehouse-inbound-grid',
			'dataProvider' => $model->search(),
			'filter' => $model,
			'columns' => array(
				//'id',
				array(
					'name' => 'projectId',
					'type' => 'raw',
					'value' => '$data->project->name',
					'filter' => CHtml::listData(Project::getAll(), 'id', 'name')
				),
				'submitDate',
				'token',
				'deliveryNumber',
				'note',
				'handler',
				array(
					'name' => 'warehouseManagerId',
					'type' => 'raw',
					'value' => '$data->warehouseManager->fullName',
					'filter' => CHtml::listData(
						Employee::findAllByTag('MATERIAL_WAREHOUSE_MANAGER'), 'id', 'fullName')
				),
				'createTime',
				/*
				'createUserId',
				'updateTime',
				'updateUserId',
				 */
				array(
					'class' => 'CButtonColumn',
				),
			),
		));
?>
